<template>
	<view>
		<view>
			<!-- <view class="browsing-date">2020-08-27</view> -->
			<view class="recommendList" v-for="(item,index) in list" @click="BrowsingHistoryClick(item.url)">
				<view class="lendingNum">
					<image :src="item.image" mode=""></image>
					<view class="lendingBrand">{{item.name}}</view>
					<view class="lendingPrice">{{item.quota}}</view>
					<view class="lendingQuota">平均额度（元)</view>
				</view>
				<view class="lendingInfor">
					<view>{{item.info[0]}}</view>
					<view>{{item.info[1]}}</view>
					<view>{{item.info[2]}}</view>
				</view>
			</view>
		</view>
		<view class="rddfooter">
			融 多 多 贷 款  ·  您 的 贷 款 专 家
		</view>
	</view>
</template>

<script>
	import {VUE_API_URL} from "@/components/pulugins/index"
	export default {
		data() {
			return {
				list:'',
				
			}
		},
		onShow() {
			this.getBrowsingHistory();
		},
		methods: {
			getBrowsingHistory(){
				var that = this;
				uni.request({
				    url: VUE_API_URL + 'browse/list', 
					method:'POST',
				    data: {}, 
				    header: {
				        'Authori-zation': 'Bearer ' + uni.getStorageSync('token') //自定义请求头信息
				    },
				    success: (res) => {
						var data = res.data.data
						console.log(data)
						that.list = data;
				    }
				});
			},
			BrowsingHistoryClick(url){
				window.location.href=url;
			},
			
		}
	}
</script>

<style>
	page{
		background: #F8F8F8;
	}
	.browsing-date{
		height: 90rpx;
		font-size: 24rpx;
		font-family: PingFang SC;
		font-weight: 500;
		color: #888888;
		line-height: 90rpx;
		padding-left: 51rpx;
	}
	.recommendList{
		/* height: 156rpx; */
		border-top: 2rpx solid #F8F8F8;
		padding: 30rpx 0 30rpx 50rpx;
		background: #FFFFFF;
	}
	.lendingNum{
		display: inline-block;
		font-family: PingFang SC;
		width: 200rpx;
	}
	.lendingNum image{
		width: 24rpx;
		height: 27rpx;
	}
	.lendingInfor{
		display: inline-block;
		font-size: 26rpx;
		font-family: PingFang SC;
		font-weight: 300;
		color: #000000;
		line-height: 50rpx;
		margin-left: 40rpx;
	}
	.lendingBrand{
		font-size: 28rpx;
		font-weight: bold;
		color: #000000;
		line-height: 23rpx;
		margin-left: 20rpx;
		display: inline-block;
	}
	.lendingPrice{
		font-size: 60rpx;
		font-weight: bold;
		color: #DFAF7F;
		line-height: 100rpx;
	}
	.lendingQuota{
		font-size: 26rpx;
		font-weight: 300;
		color: #000000;
		line-height: 23rpx;
	}
	.rddfooter{
		text-align: center;
		font-weight: 500;
		color: #888888;
		margin: 40rpx 0 90rpx 0;
	}

</style>
